package com.aube.tinker;

import android.content.Context;

import com.tencent.tinker.lib.tinker.Tinker;
import com.tencent.tinker.lib.tinker.TinkerInstaller;

/**
 * Created by huyaonan on 16/11/10.
 */
public class TinkerHelper {

    public static void checkAndLoadPatch(final Context context) {
        String version = "";

        PatchDownloader.getInstance(context).getPatchInfo("", new PatchDownloader.IPatchLoadListener() {
            @Override
            public void onSuccess(String path) {
                Tinker tinker = Tinker.with(context);
                if (tinker.isTinkerLoaded()) {
                }
                TinkerInstaller.onReceiveUpgradePatch(context, path);
            }
        });
    }

}
